<?php

/* @var $this yii\web\View */
/* @var $form yii\bootstrap\ActiveForm */
/* @var $model \common\models\LoginForm *//*
**Team :
**Coding by 曾钰媛 1511240 170705
**This is the signup layout 
*/


use yii\helpers\Html;
use yii\bootstrap\ActiveForm;
use yii\helpers\Url;

$this->title = 'Login';
$this->params['breadcrumbs'][] = $this->title;
?>
<body>
<div class="htmleaf-container">
	<div class="wrapper">
		<div class="container">
			<h1>Welcome</h1>
			
			<?php $form = ActiveForm::begin(['id' => 'login-form']); ?>

                <?= $form->field($model, 'username',[
				     'inputOptions'=>[
					     'placeholder' => 'Username',
				      ],
					  'inputTemplate'=>
					   '<div class=input>
					   <type="text" placeholder="Username">{input}
					   </div>',]
				     )
					 ->label(false)
					 ?>

                <?= $form->field($model, 'password',[
				     'inputOptions'=>[
					     'placeholder' => 'Password',
				      ],
					  'inputTemplate'=>
					   '<div class=input>
					   <type="password" placeholder="  Password">{input}
					   </div>',]
				)->passwordInput()
				->label(false)?>
				<?= $form->field($model, 'rememberMe')->checkbox() ?>


                <div class="form-group">
                    <?= Html::submitButton('Login', ['class' => 'btn btn-primary', 'name' => 'login-button']) ?>
                </div>
				<div>
					<a href="<?php echo Url::to(['site/signup']) ?>"><label class = 'btn btn-primary' style="width:250px;">SignUp</label></a>
                </div>

            <?php ActiveForm::end(); ?>
    
		</div>
		
		<ul class="bg-bubbles">
			<li></li>
			<li></li>
			<li></li>
			<li></li>
			<li></li>
			<li></li>
			<li></li>
			<li></li>
			<li></li>
			<li></li>
		</ul>
	</div>
</div>

<script src="js/jquery-2.1.1.min.js" type="text/javascript"></script>
<script>
$('#login-button').click(function (event) {
	event.preventDefault();
	$('form').fadeOut(500);
	$('.wrapper').addClass('form-success');
});
</script>

</body>


 
